﻿package test.rpg {
	import gear.core.Game;
	import gear.log4a.Logger;
	import gear.rpc.AMF3Call;
	import gear.rpc.Service;

	/**
	 * @author bright
	 * @version 20101025
	 */
	[SWF(width=550,height=400,backgroundColor=0x333333,frameRate=48)]
	public class TestService extends Game {
		private function call_test(value : Object) : void {
			Logger.debug(value);
		}

		override protected function startup() : void {
			var service : Service = new Service("http://127.0.0.1:1800/gateway");
			// service.addCall(new AMF3Call("Service.hello", call_test, {name:"liming"}));
			// var service : Service = new Service("http://hero.data.zlonggames.com/gateway.php");
			for (var i : int = 0;i < 1;i++) {
				service.addCall(new AMF3Call("TestalsoService.test", call_test, {name:"liming"}));
			}
		}
	}
}